package com.aaa.service;

import com.aaa.entity.Role;
import com.aaa.entity.Users;
import com.aaa.util.DefaultMsg;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface UserService extends IService<Users> {
    List<Users> listAll(String keyword);

    //    添加或者修改
    DefaultMsg saveOrUpdate(Users users, String rolesId);

    DefaultMsg delete(Long uid);

    //    getUserRolesCountByUid
    Integer getUserRolesCountByUid(Long uid);

    //    根据uid和rid delRole
    int delRole(Long uid, Long rid);

    //    重置密码
    int resetPassword(Long uid);

    List<Role> listAllRole();
}
